<?php

namespace app\ljhs\controller;
use app\common\controller\Ljhs;
use app\admin\model\DocumentCategories;
use app\common\model\Document as DocumentModel;
use think\Db;
/**
 * 用户接口
 */
class Document extends Ljhs
{
    protected $noNeedLogin = [];
    protected $noNeedRight = '*';

    //获取网盘分类
    public function getCategoryList()
    {
        $list = DocumentCategories::all();
        return $this->success('成功',$list);
    }

    //获取网盘文件列表
    public function getList()
    {
        $category_id = $this->request->post('category_id');
        $list = DocumentModel::where('document_categories_id',$category_id)->select();
        return $this->success('成功',$list);
    }


}
